home *** CD-ROM | disk | FTP | other *** search
- IsDisk.TXT (Taken from the ISDISK.ASM file)
- by Kenneth Chan CIS:72662,1305
-
- NOTE: ISDISK.ZIP in the DBASE forum on CompuServe (Library 4)
- contains the .ASM source code for this .BIN file.
-
- Based on DISK.ASM/DISK.BIN by Kenneth N. Getz (no relation)
-
- Diskette checker. Detects whether a formatted diskette is in the
- diskette drive, and if it is write-protected.
-
- Usage
- -----
- In dBASE IV, after LOADing, use the CALL() function. The expression
-
- call( "ISDISK", "A" ) or
- call( "ISDISK", "B" )
-
- will return one of three things:
-
- (1) The drive letter ("A" or "B") that was checked, if the disk is OK
- (2) A "W" if the disk is OK, but write-protected
- (3) A "X" if the disk or drive is not OK
-
- This .BIN should also work with dBASE III, although it has not been
- tested there; the CALL command must be used since dBASE III does not
- have the CALL() function.
-
- To use the CALL command, you need to initialize a memvar and pass that
- WITH the CALL, e.g.
-
- cDrive = "A"
- call ISDISK with cDrive
-
- cDrive will then contain "A", "W", or "X". This also works in dBASE IV.
-
- IsDisk works by reading the second sector of the diskette and writing it
- back to the disk. This avoids writing to the first sector, the boot
- sector, which would cause anti-virus TSRs to get suspicious.
-
- This program is hereby placed in the public domain. No warranties are
- expressed or implied. USE AT YOUR OWN RISK!
-
- --------
- 12/02/93 v1.0
-